<template>
	<view class="flex align-center justify-between">
	  <image class="rounded-10" :src="!api? item.logo_image : $_BASE_IMG_API+ item.logo_image" :style="{width: imgSize, height: imgSize}"></image>
	  <view class="flex-1 flex justify-between u-m-l-20">
	    <view class="left">
				<view class="text-ellipsis" style="width: 250rpx;">
					<text class="u-font-28" >{{item.store_name}}</text>
				</view>
	      <view class="flex align-center u-m-t-16" style="height: 30rpx;line-height: 30rpx;">
					<!-- <u-icon name="account-fill"></u-icon> -->
					<uni-icons type="contact-filled"></uni-icons>
	        <text class="u-p-l-10 u-font-24">{{item.favorites}}人</text>
	      </view>
	    </view>
	    <view class="right flex align-center">
	      <view class="pr-2">
					<uni-tag text="进店逛逛" :circle="true" inverted customStyle="color: #FF1212; border-color: #FF1212" @click="toSupplier"></uni-tag>
	      </view>
	    </view>
	  </view>
	</view>
</template>

<script>
	export default {
		name:"supplier-sec-item",
    props:{
			api: {
				type: [Boolean,String],
				default: false
			},
      item: {
        type: Object,
        default() {
          return {}
        }
      },
      imgSize: {
        type: String,
        default: '147rpx'
      }
    },
		data() {
			return {
			};
		},
		methods: {
			toSupplier() {
				uni.navigateTo({
					url:'/pages/supplierPage/supplierIndex/supplierIndex?id=' + this.item.merch_id
				})
			}
		}
	}
</script>

<style lang="scss">

</style>
